package com.zenithmind.library.pojo.dto;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import java.time.LocalDate;

/**
 * 借阅图书DTO
 * 
 * @author ZenithMind
 * @since 2024-06-14
 */
@Data
@Schema(name = "借阅图书DTO", description = "借阅图书时的数据传输对象")
public class BorrowBookDTO {

    @NotBlank(message = "用户ID不能为空")
    @Schema(description = "借阅用户ID", example = "1", required = true)
    private String userId;

    @NotBlank(message = "图书ID不能为空")
    @Schema(description = "图书ID", example = "1", required = true)
    private String bookId;

    @Schema(description = "图书副本ID（可选，系统自动分配可用副本）", example = "1")
    private String bookCopyId;

    @Schema(description = "借阅天数（可选，使用系统默认值）", example = "30")
    private Integer borrowDays;

    @Schema(description = "应还日期（可选，系统自动计算）", example = "2024-07-14")
    private LocalDate dueDate;

    @Schema(description = "借阅备注", example = "学习用书")
    private String borrowRemarks;

    @Schema(description = "操作员ID", example = "admin")
    private String operatorId;
}
